from django.db import models
class User(models.Model):
    name = models.CharField(max_length=50)
    word = models.CharField(max_length=100)
    dengji = models.IntegerField(default=1)#1.普通用户2.VIP
    class Meta:
        db_table = 'user'
class Book(models.Model):
    bname = models.CharField(max_length=50)
    modney = models.IntegerField()
    waijian = models.ForeignKey(User,on_delete=models.CASCADE)
    class Meta:
        db_table = 'book'


# Create your models here.
